package com.ruoyi.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 同步日志对象 sync_log
 * 
 * @author ruoyi
 */
public class SyncLog extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 日志ID */
    private Long logId;

    /** 同步任务ID */
    private Long syncId;

    /** 任务名称 */
    @Excel(name = "任务名称")
    private String syncName;

    /** 操作类型（0同步开始，1同步完成，2同步错误） */
    @Excel(name = "操作类型", readConverterExp = "0=同步开始,1=同步完成,2=同步错误")
    private String operationType;

    /** 开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date startTime;

    /** 结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date endTime;

    /** 耗时(秒) */
    @Excel(name = "耗时(秒)")
    private Long costTime;

    /** 状态（0正常 1异常） */
    @Excel(name = "状态", readConverterExp = "0=正常,1=异常")
    private String status;

    /** 详细信息 */
    private String detail;

    public void setLogId(Long logId) 
    {
        this.logId = logId;
    }

    public Long getLogId() 
    {
        return logId;
    }
    
    public void setSyncId(Long syncId) 
    {
        this.syncId = syncId;
    }

    public Long getSyncId() 
    {
        return syncId;
    }
    
    public void setSyncName(String syncName) 
    {
        this.syncName = syncName;
    }

    public String getSyncName() 
    {
        return syncName;
    }
    
    public void setOperationType(String operationType) 
    {
        this.operationType = operationType;
    }

    public String getOperationType() 
    {
        return operationType;
    }
    
    public void setStartTime(Date startTime) 
    {
        this.startTime = startTime;
    }

    public Date getStartTime() 
    {
        return startTime;
    }
    
    public void setEndTime(Date endTime) 
    {
        this.endTime = endTime;
    }

    public Date getEndTime() 
    {
        return endTime;
    }
    
    public void setCostTime(Long costTime) 
    {
        this.costTime = costTime;
    }

    public Long getCostTime() 
    {
        return costTime;
    }
    
    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }
    
    public void setDetail(String detail) 
    {
        this.detail = detail;
    }

    public String getDetail() 
    {
        return detail;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("logId", getLogId())
            .append("syncId", getSyncId())
            .append("syncName", getSyncName())
            .append("operationType", getOperationType())
            .append("startTime", getStartTime())
            .append("endTime", getEndTime())
            .append("costTime", getCostTime())
            .append("status", getStatus())
            .append("detail", getDetail())
            .toString();
    }
} 